home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1993 July / InfoMagic USENET CD-ROM July 1993.ISO / sources / unix / volume24 / cvs1.2upgrade / part01 next >
Encoding:
Internet Message Format  |  1991-03-05  |  53.6 KB

  1. Subject:  v24i014:  CVS upgrade for RCS5.5 support, Part01/02
  2. Newsgroups: comp.sources.unix
  3. Approved: rsalz@uunet.UU.NET
  4. X-Checksum-Snefru: 1203dc5b 6240d01a 965caad8 07605ecc
  5.  
  6. Submitted-by: Brian Berliner <berliner@central.sun.com>
  7. Posting-number: Volume 24, Issue 14
  8. Archive-name: cvs1.2upgrade/part01
  9.  
  10. This set of patches brings CVS 1.0 (with Patch01 applied) to patchlevel 2.
  11. I also call this release "CVS 1.2".
  12.  
  13. The "ChangeLog" file describes the changes made with this release.  The
  14. major functional addition is basic support for the recently released RCS 5.5
  15. release.
  16.  
  17. CVS 1.0 was originally released through comp.sources.unix in volume22.
  18. You can either apply this patch to the original CVS 1.0 distribution
  19. found on uunet.uu.net in the comp.sources.unix/volume22/cvs-berliner directory,
  20. or just pickup the entire CVS 1.2 distribution from either:
  21.  
  22.     prep.ai.mit.edu in pub/gnu/cvs-1.2.tar.Z
  23.             or
  24.     uunet.uu.net in gnu/cvs-1.2.tar.Z
  25.  
  26. Save this patch as "Patch02" in your top-level "cvs" directory and apply with:
  27.  
  28.     patch -p < Patch02
  29.  
  30. Good luck!
  31.  
  32.     Brian Berliner
  33.     berliner@sun.com
  34.  
  35. [ Note that Patch02 was split into two parts for posting; see the PACKNOTES
  36.   file --r$ ]
  37.  
  38. #! /bin/sh
  39. # This is a shell archive.  Remove anything before this line, then feed it
  40. # into a shell via "sh file" or similar.  To overwrite existing files,
  41. # type "sh file -c".
  42. # The tool that generated this appeared in the comp.sources.unix newsgroup;
  43. # send mail to comp-sources-unix@uunet.uu.net if you want that tool.
  44. # Contents:  PACKNOTES MANIFEST Patch02.01
  45. # Wrapped by rsalz@litchi.bbn.com on Mon Feb 25 16:05:38 1991
  46. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  47. echo If this archive is complete, you will see the following message:
  48. echo '          "shar: End of archive 1 (of 2)."'
  49. if test -f 'PACKNOTES' -a "${1}" != "-c" ; then 
  50.   echo shar: Will not clobber existing file \"'PACKNOTES'\"
  51. else
  52.   echo shar: Extracting \"'PACKNOTES'\" \(82 characters\)
  53.   sed "s/^X//" >'PACKNOTES' <<'END_OF_FILE'
  54. X# "Patch02" was split into 2 parts; to create it, do
  55. X    cat Patch02.0[1-9] >Patch02
  56. END_OF_FILE
  57.   if test 82 -ne `wc -c <'PACKNOTES'`; then
  58.     echo shar: \"'PACKNOTES'\" unpacked with wrong size!
  59.   fi
  60.   # end of 'PACKNOTES'
  61. fi
  62. if test -f 'MANIFEST' -a "${1}" != "-c" ; then 
  63.   echo shar: Will not clobber existing file \"'MANIFEST'\"
  64. else
  65.   echo shar: Extracting \"'MANIFEST'\" \(279 characters\)
  66.   sed "s/^X//" >'MANIFEST' <<'END_OF_FILE'
  67. X   File Name        Archive #    Description
  68. X----------------------------------------------------------
  69. XPACKNOTES                  1    Warnings about long lines, etc
  70. XMANIFEST                   1    This shipping list
  71. XPatch02.01                 1    (part 1)
  72. XPatch02.02                 2    (part 2)
  73. END_OF_FILE
  74.   if test 279 -ne `wc -c <'MANIFEST'`; then
  75.     echo shar: \"'MANIFEST'\" unpacked with wrong size!
  76.   fi
  77.   # end of 'MANIFEST'
  78. fi
  79. if test -f 'Patch02.01' -a "${1}" != "-c" ; then 
  80.   echo shar: Will not clobber existing file \"'Patch02.01'\"
  81. else
  82.   echo shar: Extracting \"'Patch02.01'\" \(49821 characters\)
  83.   sed "s/^X//" >'Patch02.01' <<'END_OF_FILE'
  84. Xdiff -c /dev/null ChangeLog:1.1
  85. X*** /dev/null    Wed Feb  6 11:32:17 1991
  86. X--- ChangeLog    Wed Feb  6 11:32:17 1991
  87. X***************
  88. X*** 0 ****
  89. X--- 1,89 ----
  90. X+ Wed Feb  6 10:10:58 1991  Brian Berliner  (berliner at sun.com)
  91. X+ 
  92. X+     * Changes from CVS 1.0 Patchlevel 1 to CVS 1.0 Patchlevel 2; also
  93. X+     known as "Changes from CVS 1.1 to CVS 1.2".
  94. X+ 
  95. X+     * Major new support with this release is the ability to use the
  96. X+     recently-posted RCS 5.5 distribution with CVS 1.2.  See below for
  97. X+     other assorted bug-fixes that have been thrown in.
  98. X+ 
  99. X+     * ChangeLog (new): Added Emacs-style change-log file to CVS 1.2
  100. X+     release.  Chronological description of changes between release.
  101. X+ 
  102. X+     * README: Small fixes to installation instructions.  My email
  103. X+     address is now "berliner@sun.com".
  104. X+ 
  105. X+     * src/Makefile: Removed "rcstime.h".  Removed "depend" rule.
  106. X+ 
  107. X+     * src/partime.c:  Updated to RCS 5.5 version with hooks for CVS.
  108. X+     * src/maketime.c: Updated to RCS 5.5 version with hooks for CVS.
  109. X+     * src/rcstime.h:  Removed from the CVS 1.2 distribution.
  110. X+     Thanks to Paul Eggert <eggert@twinsun.com> for these changes.
  111. X+ 
  112. X+     * src/checkin.csh: Support for RCS 5.5 parsing.
  113. X+     Thanks to Paul Eggert <eggert@twinsun.com> for this change.
  114. X+ 
  115. X+     * src/collect_sets.c (Collect_Sets): Be quieter if "-f" option is
  116. X+     specified.  When checking out files on-top-of other files that CVS
  117. X+     doesn't know about, run a diff in the hopes that they are really
  118. X+     the same file before aborting.
  119. X+ 
  120. X+     * src/commit.c (branch_number): Fix for RCS 5.5 parsing.
  121. X+     Thanks to Paul Eggert <eggert@twinsun.com> for this change.
  122. X+ 
  123. X+     * src/commit.c (do_editor): Bug fix - fprintf missing argument
  124. X+     which sometimes caused core dumps.
  125. X+ 
  126. X+     * src/modules.c (process_module): Properly NULL-terminate
  127. X+     update_dir[] in all cases.
  128. X+ 
  129. X+     * src/no_difference.c (No_Difference): The wrong RCS revision was
  130. X+     being registered in certain (strange) cases.
  131. X+ 
  132. X+     * src/patch.c (get_rcsdate): New algorithm.  No need to call
  133. X+     maketime() any longer.
  134. X+     Thanks to Paul Eggert <eggert@twinsun.com> for this change.
  135. X+ 
  136. X+     * src/patchlevel.h: Increased patch level to "2".
  137. X+ 
  138. X+     * src/subr.c (isdir, islink): Changed to compare stat mode bits
  139. X+     correctly.
  140. X+ 
  141. X+     * src/tag.c (tag_file): Added support for following symbolic links
  142. X+     that are in the master source repository when tagging.  Made tag
  143. X+     somewhat quieter in certain cases.
  144. X+ 
  145. X+     * src/update.c (update_process_lists): Unlink the user's file if it
  146. X+     was put on the Wlist, meaning that the user's file is not modified
  147. X+     and its RCS file has been removed by someone else.
  148. X+ 
  149. X+     * src/update.c (update): Support for "cvs update dir" to correctly
  150. X+     just update the argument directory "dir".
  151. X+ 
  152. X+     * src/cvs.h: Fixes for RCS 5.5 parsing.
  153. X+     * src/version_number.c (Version_Number): Fixes for parsing RCS 5.5
  154. X+     and older RCS-format files.
  155. X+     Thanks to Paul Eggert <eggert@twinsun.com> for these changes.
  156. X+ 
  157. X+     * src/version_number.c (Version_Number): Bug fixes for "-f" option.
  158. X+     Bug fixes for parsing with certain branch numbers.  RCS
  159. X+     revision/symbol parsing is much more solid now.
  160. X+ 
  161. X+ Wed Feb 14 10:01:33 1990  Brian Berliner  (berliner at sun.com)
  162. X+ 
  163. X+     * Changes from CVS 1.0 Patchlevel 0 to CVS 1.0 Patchlevel 1; also
  164. X+     known as "Changes from CVS 1.0 to CVS 1.1".
  165. X+ 
  166. X+     * src/patch.c (get_rcsdate): Portability fix.  Replaced call to
  167. X+     timelocal() with call to maketime().
  168. X+ 
  169. X+ Mon Nov 19 23:15:11 1990  Brian Berliner  (berliner at prisma.com)
  170. X+ 
  171. X+     * Sent CVS 1.0 release to comp.sources.unix moderator and FSF.
  172. X+ 
  173. X+     * Special thanks to Dick Grune <dick@cs.vu.nl> for his work on the
  174. X+     1986 version of CVS and making it available to the world.  Dick's
  175. X+     version is available on uunet.uu.net in the
  176. X+     comp.sources.unix/volume6/cvs directory.
  177. X+ 
  178. X+ $Id: ChangeLog,v 1.1 91/02/06 18:29:01 berliner Exp $
  179. Xdiff -c README:1.3 README:1.3.1.2
  180. X*** README:1.3    Wed Feb  6 11:32:17 1991
  181. X--- README    Wed Feb  6 11:32:17 1991
  182. X***************
  183. X*** 1,4 ****
  184. X! $Id: README,v 1.3 89/11/19 23:15:11 berliner Exp $
  185. X  
  186. X  
  187. X                 CVS Kit, Version 1.0
  188. X--- 1,4 ----
  189. X! $Id: README,v 1.3.1.2 91/02/06 18:26:40 berliner Exp $
  190. X  
  191. X  
  192. X                 CVS Kit, Version 1.0
  193. X***************
  194. X*** 36,46 ****
  195. X  volume 6 release sometime in 1986.  This original version was a collection
  196. X  of shell scripts. 
  197. X  
  198. X! Brian Berliner from Prisma, Inc. converted the original CVS shell scripts
  199. X! into reasonably fast C and added many, many features to support software
  200. X! release control functions.  See the manual page in the "man" directory, and
  201. X! a copy of the USENIX article presented at the Winter 1990 USENIX
  202. X! Conference, Washington D.C., is included in the "doc" directory.
  203. X  
  204. X  This code has been tested extensively on Sun-4 and Sun-3 platforms, all
  205. X  running SunOS 4.X.  Your mileage may vary for other systems, and I would
  206. X--- 36,47 ----
  207. X  volume 6 release sometime in 1986.  This original version was a collection
  208. X  of shell scripts. 
  209. X  
  210. X! ! Brian Berliner from Prisma, Inc. (now at Sun Microsystems, Inc.) converted
  211. X! ! the original CVS shell scripts into reasonably fast C and added many, many
  212. X! ! features to support software release control functions.  See the manual
  213. X! ! page in the "man" directory.  A copy of the USENIX article presented
  214. X! ! at the Winter 1990 USENIX Conference, Washington D.C., is included in
  215. X! ! the "doc" directory.
  216. X  
  217. X  This code has been tested extensively on Sun-4 and Sun-3 platforms, all
  218. X  running SunOS 4.X.  Your mileage may vary for other systems, and I would
  219. X***************
  220. X*** 120,125 ****
  221. X--- 121,127 ----
  222. X      following commands:
  223. X  
  224. X          mkdir $CVSROOT/cvs
  225. X+         make clean
  226. X          checkin -m 'CVS 1.0 distribution' cvs CVS CVS1_0
  227. X  
  228. X  11) Having done step 10, one should be able to checkout a copy of the CVS
  229. X***************
  230. X*** 135,141 ****
  231. X      can usually be retrieved with the "cvs checkout modules" command, and
  232. X      definitely with the "cvs checkout CVSROOT.adm" command.
  233. X  
  234. X! 13) PLEASE report any problems to me, berliner@prisma.com (Brian Berliner)
  235. X      and I will try to collect patches and enhancements into future CVS
  236. X      distributions.  "patch" format files are best, using context diffs,
  237. X      if you will.
  238. X--- 137,143 ----
  239. X      can usually be retrieved with the "cvs checkout modules" command, and
  240. X      definitely with the "cvs checkout CVSROOT.adm" command.
  241. X  
  242. X! 13) PLEASE report any problems to me, berliner@sun.com (Brian Berliner)
  243. X      and I will try to collect patches and enhancements into future CVS
  244. X      distributions.  "patch" format files are best, using context diffs,
  245. X      if you will.
  246. X***************
  247. X*** 143,146 ****
  248. X  14) GOOD LUCK!
  249. X  
  250. X                      Brian Berliner
  251. X!                     berliner@prisma.com
  252. X--- 145,148 ----
  253. X  14) GOOD LUCK!
  254. X  
  255. X                      Brian Berliner
  256. X!                     berliner@sun.com
  257. Xdiff -c src/Makefile:1.20 src/Makefile:1.20.1.1
  258. X*** src/Makefile:1.20    Wed Feb  6 11:32:10 1991
  259. X--- src/Makefile    Wed Feb  6 11:32:10 1991
  260. X***************
  261. X*** 1,5 ****
  262. X  #
  263. X! #    $Id: Makefile,v 1.20 89/11/20 00:06:32 berliner Exp $
  264. X  #
  265. X  # Makefile for CVS
  266. X  #
  267. X--- 1,5 ----
  268. X  #
  269. X! #    $Id: Makefile,v 1.20.1.1 91/01/18 12:04:00 berliner Exp $
  270. X  #
  271. X  # Makefile for CVS
  272. X  #
  273. X***************
  274. X*** 23,29 ****
  275. X  CSHEXT=        .csh
  276. X  CSHELLS=    checkin${CSHEXT}
  277. X  
  278. X! HEADERS=    cvs.h patchlevel.h rcstime.h
  279. X  DESTDIR=    /usr/local/bin
  280. X  
  281. X  ALLSRCS=    ${COMMONSRCS} ${CVSSRCS} ${MODSRCS}
  282. X--- 23,30 ----
  283. X  CSHEXT=        .csh
  284. X  CSHELLS=    checkin${CSHEXT}
  285. X  
  286. X! HEADERS=    cvs.h patchlevel.h
  287. X! ALLOBJS=    ${COMMONOBJS} ${CVSOBJS} ${MODOBJS}
  288. X  DESTDIR=    /usr/local/bin
  289. X  
  290. X  ALLSRCS=    ${COMMONSRCS} ${CVSSRCS} ${MODSRCS}
  291. X***************
  292. X*** 69,234 ****
  293. X      done
  294. X  
  295. X  depend:
  296. X!     /bin/rm -f makedep
  297. X!     for i in ${ALLSRCS}; do \
  298. X!         ${CC} -M ${INCPATH} $$i | \
  299. X!         awk ' { if ($$1 != prev) \
  300. X!         { if (rec != "") print rec; rec = $$0; prev = $$1; } \
  301. X!         else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \
  302. X!         else rec = rec " " $$2 } } \
  303. X!         END { print rec } ' >> makedep; done
  304. X!     echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep
  305. X!     echo '$$r makedep' >>eddep
  306. X!     echo 'w' >>eddep
  307. X!     cp Makefile Makefile.bak
  308. X!     ed - Makefile < eddep
  309. X!     /bin/rm eddep makedep
  310. X!     echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
  311. X!     echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
  312. X!     echo '# see make depend above' >> Makefile
  313. X! 
  314. X! # DO NOT DELETE THIS LINE
  315. X! 
  316. X! subr.o: subr.c /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  317. X! subr.o: /usr/include/sys/stat.h /usr/include/sys/file.h
  318. X! subr.o: /usr/include/sys/fcntlcom.h /usr/include/varargs.h ./cvs.h
  319. X! subr.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  320. X! add.o: add.c /usr/include/sys/param.h /usr/include/machine/param.h
  321. X! add.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  322. X! add.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h ./cvs.h
  323. X! add.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  324. X! build_entry.o: build_entry.c /usr/include/sys/param.h
  325. X! build_entry.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  326. X! build_entry.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  327. X! build_entry.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  328. X! build_entry.o: /usr/include/string.h /usr/include/stdio.h
  329. X! checkin.o: checkin.c /usr/include/sys/param.h /usr/include/machine/param.h
  330. X! checkin.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  331. X! checkin.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  332. X! checkin.o: /usr/include/ctype.h ./cvs.h /usr/include/strings.h
  333. X! checkin.o: /usr/include/string.h /usr/include/stdio.h
  334. X! checkout.o: checkout.c /usr/include/sys/param.h /usr/include/machine/param.h
  335. X! checkout.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  336. X! checkout.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  337. X! checkout.o: /usr/include/ndbm.h ./cvs.h /usr/include/strings.h
  338. X! checkout.o: /usr/include/string.h /usr/include/stdio.h
  339. X! collect_sets.o: collect_sets.c /usr/include/sys/param.h
  340. X! collect_sets.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  341. X! collect_sets.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  342. X! collect_sets.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  343. X! collect_sets.o: /usr/include/string.h /usr/include/stdio.h
  344. X! commit.o: commit.c /usr/include/sys/param.h /usr/include/machine/param.h
  345. X! commit.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  346. X! commit.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  347. X! commit.o: /usr/include/sys/types.h /usr/include/sys/stat.h /usr/include/ctype.h
  348. X! commit.o: ./cvs.h /usr/include/strings.h /usr/include/string.h
  349. X! commit.o: /usr/include/stdio.h
  350. X! create_admin.o: create_admin.c /usr/include/sys/param.h
  351. X! create_admin.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  352. X! create_admin.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  353. X! create_admin.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  354. X! create_admin.o: /usr/include/string.h /usr/include/stdio.h
  355. X! diff.o: diff.c /usr/include/sys/param.h /usr/include/machine/param.h
  356. X! diff.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  357. X! diff.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h ./cvs.h
  358. X! diff.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  359. X! entries_file.o: entries_file.c ./cvs.h /usr/include/strings.h
  360. X! entries_file.o: /usr/include/string.h /usr/include/stdio.h
  361. X! find_names.o: find_names.c /usr/include/sys/param.h
  362. X! find_names.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  363. X! find_names.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  364. X! find_names.o: /usr/include/sys/sysmacros.h /usr/include/sys/types.h
  365. X! find_names.o: /usr/include/dirent.h /usr/include/sys/dirent.h ./cvs.h
  366. X! find_names.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  367. X! join.o: join.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  368. X! join.o: /usr/include/stdio.h
  369. X! locate_rcs.o: locate_rcs.c /usr/include/sys/param.h
  370. X! locate_rcs.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  371. X! locate_rcs.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  372. X! locate_rcs.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  373. X! locate_rcs.o: /usr/include/string.h /usr/include/stdio.h
  374. X! log.o: log.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  375. X! log.o: /usr/include/stdio.h
  376. X! main.o: main.c /usr/include/sys/param.h /usr/include/machine/param.h
  377. X! main.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  378. X! main.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h ./cvs.h
  379. X! main.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  380. X! main.o: ./patchlevel.h
  381. X! maketime.o: maketime.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  382. X! maketime.o: /usr/include/stdio.h ./rcstime.h /usr/include/sys/types.h
  383. X! maketime.o: /usr/include/sys/sysmacros.h /usr/include/sys/timeb.h
  384. X! modules.o: modules.c /usr/include/sys/param.h /usr/include/machine/param.h
  385. X! modules.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  386. X! modules.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  387. X! modules.o: /usr/include/sys/file.h /usr/include/sys/fcntlcom.h
  388. X! modules.o: /usr/include/ndbm.h ./cvs.h /usr/include/strings.h
  389. X! modules.o: /usr/include/string.h /usr/include/stdio.h
  390. X! name_repository.o: name_repository.c /usr/include/sys/param.h
  391. X! name_repository.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  392. X! name_repository.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  393. X! name_repository.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  394. X! name_repository.o: /usr/include/string.h /usr/include/stdio.h
  395. X! no_difference.o: no_difference.c /usr/include/sys/param.h
  396. X! no_difference.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  397. X! no_difference.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  398. X! no_difference.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  399. X! no_difference.o: /usr/include/string.h /usr/include/stdio.h
  400. X! options.o: options.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  401. X! options.o: /usr/include/stdio.h
  402. X! partime.o: partime.c /usr/include/stdio.h /usr/include/ctype.h ./rcstime.h
  403. X! patch.o: patch.c /usr/include/sys/param.h /usr/include/machine/param.h
  404. X! patch.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  405. X! patch.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  406. X! patch.o: /usr/include/time.h /usr/include/ndbm.h /usr/include/dirent.h
  407. X! patch.o: /usr/include/sys/dirent.h /usr/include/ctype.h ./cvs.h
  408. X! patch.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  409. X! register.o: register.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  410. X! register.o: /usr/include/stdio.h
  411. X! remove.o: remove.c /usr/include/sys/param.h /usr/include/machine/param.h
  412. X! remove.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  413. X! remove.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h ./cvs.h
  414. X! remove.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  415. X! scratch_entry.o: scratch_entry.c /usr/include/sys/param.h
  416. X! scratch_entry.o: /usr/include/machine/param.h /usr/include/sys/signal.h
  417. X! scratch_entry.o: /usr/include/vm/faultcode.h /usr/include/sys/types.h
  418. X! scratch_entry.o: /usr/include/sys/sysmacros.h ./cvs.h /usr/include/strings.h
  419. X! scratch_entry.o: /usr/include/string.h /usr/include/stdio.h
  420. X! set_lock.o: set_lock.c /usr/include/sys/param.h /usr/include/machine/param.h
  421. X! set_lock.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  422. X! set_lock.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  423. X! set_lock.o: /usr/include/sys/types.h /usr/include/sys/stat.h
  424. X! set_lock.o: /usr/include/signal.h /usr/include/dirent.h
  425. X! set_lock.o: /usr/include/sys/dirent.h ./cvs.h /usr/include/strings.h
  426. X! set_lock.o: /usr/include/string.h /usr/include/stdio.h
  427. X! status.o: status.c ./cvs.h /usr/include/strings.h /usr/include/string.h
  428. X! status.o: /usr/include/stdio.h
  429. X! tag.o: tag.c /usr/include/sys/param.h /usr/include/machine/param.h
  430. X! tag.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  431. X! tag.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  432. X! tag.o: /usr/include/ndbm.h /usr/include/dirent.h /usr/include/sys/dirent.h
  433. X! tag.o: /usr/include/ctype.h ./cvs.h /usr/include/strings.h
  434. X! tag.o: /usr/include/string.h /usr/include/stdio.h
  435. X! update.o: update.c /usr/include/sys/param.h /usr/include/machine/param.h
  436. X! update.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  437. X! update.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  438. X! update.o: /usr/include/sys/types.h /usr/include/sys/stat.h
  439. X! update.o: /usr/include/dirent.h /usr/include/sys/dirent.h ./cvs.h
  440. X! update.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  441. X! version_number.o: version_number.c /usr/include/ctype.h ./cvs.h
  442. X! version_number.o: /usr/include/strings.h /usr/include/string.h
  443. X! version_number.o: /usr/include/stdio.h
  444. X! version_ts.o: version_ts.c /usr/include/sys/types.h
  445. X! version_ts.o: /usr/include/sys/sysmacros.h /usr/include/sys/timeb.h
  446. X! version_ts.o: /usr/include/sys/stat.h /usr/include/ctype.h /usr/include/grp.h
  447. X! version_ts.o: /usr/include/pwd.h /usr/include/utmp.h ./cvs.h
  448. X! version_ts.o: /usr/include/strings.h /usr/include/string.h /usr/include/stdio.h
  449. X! mkmodules.o: mkmodules.c /usr/include/sys/param.h /usr/include/machine/param.h
  450. X! mkmodules.o: /usr/include/sys/signal.h /usr/include/vm/faultcode.h
  451. X! mkmodules.o: /usr/include/sys/types.h /usr/include/sys/sysmacros.h
  452. X! mkmodules.o: /usr/include/fcntl.h /usr/include/sys/fcntlcom.h
  453. X! mkmodules.o: /usr/include/signal.h /usr/include/ndbm.h /usr/include/ctype.h
  454. X! mkmodules.o: ./cvs.h /usr/include/strings.h /usr/include/string.h
  455. X! mkmodules.o: /usr/include/stdio.h
  456. X! # DEPENDENCIES MUST END AT END OF FILE
  457. X! # IF YOU PUT STUFF HERE IT WILL GO AWAY
  458. X! # see make depend above
  459. X--- 70,78 ----
  460. X      done
  461. X  
  462. X  depend:
  463. X!     @exit 0                # done by hand now
  464. X! 
  465. X! #
  466. X! # Dependencies -- done by hand since some systems don't have cc -M!
  467. X! #
  468. X! ${ALLOBJS}:    ${HEADERS}
  469. Xdiff -c src/checkin.csh:1.8 src/checkin.csh:1.8.1.1
  470. X*** src/checkin.csh:1.8    Wed Feb  6 11:32:08 1991
  471. X--- src/checkin.csh    Wed Feb  6 11:32:08 1991
  472. X***************
  473. X*** 1,6 ****
  474. X  #!/bin/csh
  475. X  #
  476. X! # $Id: checkin.csh,v 1.8 89/11/20 13:37:33 berliner Exp $
  477. X  #
  478. X  #   Copyright (c) 1989, Brian Berliner
  479. X  #
  480. X--- 1,6 ----
  481. X  #!/bin/csh
  482. X  #
  483. X! # $Id: checkin.csh,v 1.8.1.1 91/01/18 12:06:34 berliner Exp $
  484. X  #
  485. X  #   Copyright (c) 1989, Brian Berliner
  486. X  #
  487. X***************
  488. X*** 182,199 ****
  489. X          else 
  490. X          set file = ${update_dir}/Attic/${name},v
  491. X          echo "WARNING: Updating ${repository}/Attic/${name}"
  492. X!             set head = `head -1 $file`
  493. X!             set branch = `head -2 $file | ${grep} -w branch`
  494. X!             if ( $#head != 2 || $#branch != 2 ) then
  495. X              echo "ERROR: corrupted RCS file $file - aborting"
  496. X              endif
  497. X!             if ( "$head[2]" == "1.1;" && "$branch[2]" != "1.1.1;" ) then
  498. X              ${rcsbin}/rcsdiff -q -r1.1 $file > /dev/null
  499. X              if ( ! $status ) then
  500. X                  set new = 1
  501. X              endif
  502. X              else
  503. X!                 if ( "$branch[2]" != "1.1.1;" ) then
  504. X                  echo -n "WARNING: Updating locally modified file "
  505. X              echo    "${repository}/Attic/${name}"
  506. X                  endif
  507. X--- 182,203 ----
  508. X          else 
  509. X          set file = ${update_dir}/Attic/${name},v
  510. X          echo "WARNING: Updating ${repository}/Attic/${name}"
  511. X!             set headbranch = `sed -n '/^head/p; /^branch/p; 2q' $file`
  512. X!             if ( $#headbranch != 2 && $#headbranch != 4 ) then
  513. X              echo "ERROR: corrupted RCS file $file - aborting"
  514. X              endif
  515. X!         set head = "$headbranch[2]"
  516. X!         set branch = ""
  517. X!         if ( $#headbranch == 4 ) then
  518. X!             set branch = "$headbranch[4]"
  519. X!         endif
  520. X!             if ( "$head" == "1.1;" && "$branch" != "1.1.1;" ) then
  521. X              ${rcsbin}/rcsdiff -q -r1.1 $file > /dev/null
  522. X              if ( ! $status ) then
  523. X                  set new = 1
  524. X              endif
  525. X              else
  526. X!                 if ( "$branch" != "1.1.1;" ) then
  527. X                  echo -n "WARNING: Updating locally modified file "
  528. X              echo    "${repository}/Attic/${name}"
  529. X                  endif
  530. X***************
  531. X*** 200,217 ****
  532. X              endif
  533. X          endif
  534. X      else
  535. X!         set head = `head -1 $file`
  536. X!         set branch = `head -2 $file | ${grep} -w branch`
  537. X!         if ( $#head != 2 || $#branch != 2 ) then
  538. X          echo "ERROR: corrupted RCS file $file - aborting"
  539. X          endif
  540. X!         if ( "$head[2]" == "1.1;" && "$branch[2]" != "1.1.1;" ) then
  541. X          ${rcsbin}/rcsdiff -q -r1.1 $file > /dev/null
  542. X          if ( ! $status ) then
  543. X              set new = 1
  544. X          endif
  545. X          else
  546. X!             if ( "$branch[2]" != "1.1.1;" ) then
  547. X              echo -n "WARNING: Updating locally modified file "
  548. X              echo    "${repository}/${name}"
  549. X              endif
  550. X--- 204,225 ----
  551. X              endif
  552. X          endif
  553. X      else
  554. X!         set headbranch = `sed -n '/^head/p; /^branch/p; 2q' $file`
  555. X!         if ( $#headbranch != 2 && $#headbranch != 4 ) then
  556. X          echo "ERROR: corrupted RCS file $file - aborting"
  557. X          endif
  558. X!         set head = "$headbranch[2]"
  559. X!         set branch = ""
  560. X!         if ( $#headbranch == 4 ) then
  561. X!         set branch = "$headbranch[4]"
  562. X!         endif
  563. X!         if ( "$head" == "1.1;" && "$branch" != "1.1.1;" ) then
  564. X          ${rcsbin}/rcsdiff -q -r1.1 $file > /dev/null
  565. X          if ( ! $status ) then
  566. X              set new = 1
  567. X          endif
  568. X          else
  569. X!             if ( "$branch" != "1.1.1;" ) then
  570. X              echo -n "WARNING: Updating locally modified file "
  571. X              echo    "${repository}/${name}"
  572. X              endif
  573. Xdiff -c src/collect_sets.c:1.15 src/collect_sets.c:1.15.1.1
  574. X*** src/collect_sets.c:1.15    Wed Feb  6 11:32:09 1991
  575. X--- src/collect_sets.c    Wed Feb  6 11:32:09 1991
  576. X***************
  577. X*** 1,5 ****
  578. X  #ifndef lint
  579. X! static char rcsid[] = "$Id: collect_sets.c,v 1.15 89/11/19 23:19:51 berliner Exp $";
  580. X  #endif !lint
  581. X  
  582. X  /*
  583. X--- 1,5 ----
  584. X  #ifndef lint
  585. X! static char rcsid[] = "$Id: collect_sets.c,v 1.15.1.1 91/01/29 07:16:13 berliner Exp $";
  586. X  #endif !lint
  587. X  
  588. X  /*
  589. X***************
  590. X*** 75,83 ****
  591. X              ret++;
  592. X              }
  593. X          } else {        /* there is a user file */
  594. X!             warn(0, "use `cvs add' to create entry for %s",
  595. X!              update_user);
  596. X!             ret++;
  597. X          }
  598. X          } else {
  599. X          /*
  600. X--- 75,85 ----
  601. X              ret++;
  602. X              }
  603. X          } else {        /* there is a user file */
  604. X!             if (!force_tag_match) {
  605. X!             warn(0, "use `cvs add' to create entry for %s",
  606. X!                  update_user);
  607. X!             ret++;
  608. X!             }
  609. X          }
  610. X          } else {
  611. X          /*
  612. X***************
  613. X*** 92,103 ****
  614. X          } else {
  615. X              /*
  616. X               * There is a user file; print a warning and add it
  617. X!              * to the conflict list, Clist
  618. X               */
  619. X!             warn(0, "move away %s; it is in the way", update_user);
  620. X!             (void) strcat(Clist, " ");
  621. X!             (void) strcat(Clist, User);
  622. X!             ret++;
  623. X          }
  624. X          }
  625. X      } else if (VN_User[0] == '0' && VN_User[1] == '\0') {
  626. X--- 94,113 ----
  627. X          } else {
  628. X              /*
  629. X               * There is a user file; print a warning and add it
  630. X!              * to the conflict list, Clist, only if it is indeed
  631. X!              * different from what we plan to extract
  632. X               */
  633. X!             No_Difference(0);
  634. X!             if (strcmp(TS_Rcs, TS_User) == 0) {
  635. X!             (void) strcat(Olist, " ");
  636. X!             (void) strcat(Olist, User);
  637. X!             } else {
  638. X!             warn(0, "move away %s; it is in the way",
  639. X!                  update_user);
  640. X!             (void) strcat(Clist, " ");
  641. X!             (void) strcat(Clist, User);
  642. X!             ret++;
  643. X!             }
  644. X          }
  645. X          }
  646. X      } else if (VN_User[0] == '0' && VN_User[1] == '\0') {
  647. X***************
  648. X*** 210,220 ****
  649. X               * longer in the repository, a conflict is raised
  650. X               */
  651. X              if (!force_tag_match) {
  652. X!             warn(0, "conflict: %s is modified but no longer in the repository",
  653. X!                  update_user);
  654. X!             (void) strcat(Clist, " ");
  655. X!             (void) strcat(Clist, User);
  656. X!             ret++;
  657. X              }
  658. X          }
  659. X          } else if (strcmp(VN_Rcs, VN_User) == 0) {
  660. X--- 220,241 ----
  661. X               * longer in the repository, a conflict is raised
  662. X               */
  663. X              if (!force_tag_match) {
  664. X!             Locate_RCS();
  665. X!             (void) No_Difference(0);
  666. X!             if (strcmp(TS_User, TS_Rcs) == 0) {
  667. X!                 warn(0,
  668. X!         "warning: %s is not (any longer) pertinent",
  669. X!                  update_user);
  670. X!                 (void) strcat(Wlist, " ");
  671. X!                 (void) strcat(Wlist, User);
  672. X!             } else {
  673. X!                 warn(0,
  674. X!         "conflict: %s is modified but no longer in the repository",
  675. X!                  update_user);
  676. X!                 (void) strcat(Clist, " ");
  677. X!                 (void) strcat(Clist, User);
  678. X!                 ret++;
  679. X!             }
  680. X              }
  681. X          }
  682. X          } else if (strcmp(VN_Rcs, VN_User) == 0) {
  683. Xdiff -c src/commit.c:1.28 src/commit.c:1.28.1.2
  684. X*** src/commit.c:1.28    Wed Feb  6 11:32:14 1991
  685. X--- src/commit.c    Wed Feb  6 11:32:15 1991
  686. X***************
  687. X*** 1,5 ****
  688. X  #ifndef lint
  689. X! static char rcsid[] = "$Id: commit.c,v 1.28 89/11/19 23:40:32 berliner Exp $";
  690. X  #endif !lint
  691. X  
  692. X  /*
  693. X--- 1,5 ----
  694. X  #ifndef lint
  695. X! static char rcsid[] = "$Id: commit.c,v 1.28.1.2 91/01/29 07:16:59 berliner Exp $";
  696. X  #endif !lint
  697. X  
  698. X  /*
  699. X***************
  700. X*** 470,475 ****
  701. X--- 470,476 ----
  702. X      }
  703. X      (void) fclose(fp);
  704. X      if (strncmp(line, RCSBRANCH, sizeof(RCSBRANCH) - 1) != 0 ||
  705. X+     !isspace(line[sizeof(RCSBRANCH) - 1]) ||
  706. X      (cp = rindex(line, ';')) == NULL)
  707. X      return;
  708. X      *cp = '\0';                /* strip the ';' */
  709. X***************
  710. X*** 556,568 ****
  711. X      setup_tmpfile(fp, CVSEDITPREFIX);
  712. X      (void) fprintf(fp, "%sEnter Log.  Lines beginning with '%s' are removed automatically\n",
  713. X             CVSEDITPREFIX, CVSEDITPREFIX);
  714. X!     (void) fprintf(fp, "%s----------------------------------------------------------------------\n");
  715. X      (void) fclose(fp);
  716. X      (void) sprintf(prog, "%s %s", Editor, fname);
  717. X!     if (system(prog) != 0) {
  718. X!     (void) unlink(fname);
  719. X      warn(0, "warning: editor session failed");
  720. X-     }
  721. X      fp = open_file(fname, "r");
  722. X      while (fgets(line, sizeof(line), fp) != NULL) {
  723. X      if (strncmp(line, CVSEDITPREFIX, sizeof(CVSEDITPREFIX)-1) == 0)
  724. X--- 557,567 ----
  725. X      setup_tmpfile(fp, CVSEDITPREFIX);
  726. X      (void) fprintf(fp, "%sEnter Log.  Lines beginning with '%s' are removed automatically\n",
  727. X             CVSEDITPREFIX, CVSEDITPREFIX);
  728. X!     (void) fprintf(fp, "%s----------------------------------------------------------------------\n", CVSEDITPREFIX);
  729. X      (void) fclose(fp);
  730. X      (void) sprintf(prog, "%s %s", Editor, fname);
  731. X!     if (system(prog) != 0)
  732. X      warn(0, "warning: editor session failed");
  733. X      fp = open_file(fname, "r");
  734. X      while (fgets(line, sizeof(line), fp) != NULL) {
  735. X      if (strncmp(line, CVSEDITPREFIX, sizeof(CVSEDITPREFIX)-1) == 0)
  736. Xdiff -c src/cvs.h:1.24 src/cvs.h:1.24.1.1
  737. X*** src/cvs.h:1.24    Wed Feb  6 11:32:11 1991
  738. X--- src/cvs.h    Wed Feb  6 11:32:12 1991
  739. X***************
  740. X*** 1,4 ****
  741. X! /*    $Id: cvs.h,v 1.24 89/11/19 23:19:57 berliner Exp $    */
  742. X  
  743. X  #include <strings.h>
  744. X  #include <string.h>
  745. X--- 1,4 ----
  746. X! /*    $Id: cvs.h,v 1.24.1.1 91/01/18 12:13:48 berliner Exp $    */
  747. X  
  748. X  #include <strings.h>
  749. X  #include <string.h>
  750. X***************
  751. X*** 75,84 ****
  752. X  #define    RCS_MERGE_PAT    "^>>>>>>> "    /* runs "grep" with this pattern */
  753. X  #define    RCSID_PAT    "'\\$Id.*\\$'"    /* when committing files */
  754. X  #define    RCSEXT        ",v"
  755. X! #define    RCSHEAD        "head "
  756. X! #define    RCSBRANCH    "branch "
  757. X! #define    RCSSYMBOL    "symbols "
  758. X! #define    RCSDATE        "date "
  759. X  #define    RCSDESC        "desc"        /* ends the search for branches */
  760. X  #define    DATEFORM    "%02d.%02d.%02d.%02d.%02d.%02d"
  761. X  
  762. X--- 75,84 ----
  763. X  #define    RCS_MERGE_PAT    "^>>>>>>> "    /* runs "grep" with this pattern */
  764. X  #define    RCSID_PAT    "'\\$Id.*\\$'"    /* when committing files */
  765. X  #define    RCSEXT        ",v"
  766. X! #define    RCSHEAD        "head"
  767. X! #define    RCSBRANCH    "branch"
  768. X! #define    RCSSYMBOL    "symbols"
  769. X! #define    RCSDATE        "date"
  770. X  #define    RCSDESC        "desc"        /* ends the search for branches */
  771. X  #define    DATEFORM    "%02d.%02d.%02d.%02d.%02d.%02d"
  772. X  
  773. Xdiff -c src/maketime.c:1.2 src/maketime.c:1.2.1.1
  774. X*** src/maketime.c:1.2    Wed Feb  6 11:32:08 1991
  775. X--- src/maketime.c    Wed Feb  6 11:32:08 1991
  776. X***************
  777. X*** 1,19 ****
  778. X! #ifndef lint
  779. X! static char rcsid[] = "$Id: maketime.c,v 1.2 89/05/11 12:03:02 berliner Exp $";
  780. X! #endif !lint
  781. X! 
  782. X  /*
  783. X   * MAKETIME        derive 32-bit time value from TM structure.
  784. X   *
  785. X   * Usage:
  786. X!  *    long t,maketime();
  787. X   *    struct tm *tp;    Pointer to TM structure from <time.h>
  788. X!  *            NOTE: this must be extended version!!!
  789. X!  *    t = maketime(tp);
  790. X   *
  791. X   * Returns:
  792. X!  *    0 if failure; parameter out of range or nonsensical.
  793. X!  *    else long time-value.
  794. X   * Notes:
  795. X   *    This code is quasi-public; it may be used freely in like software.
  796. X   *    It is not to be sold, nor used in licensed software without
  797. X--- 1,17 ----
  798. X! #
  799. X  /*
  800. X   * MAKETIME        derive 32-bit time value from TM structure.
  801. X   *
  802. X   * Usage:
  803. X!  *    int zone;    Minutes west of GMT, or
  804. X!  *            48*60 for localtime
  805. X!  *    time_t t;
  806. X   *    struct tm *tp;    Pointer to TM structure from <time.h>
  807. X!  *    t = maketime(tp,zone);
  808. X   *
  809. X   * Returns:
  810. X!  *    -1 if failure; parameter out of range or nonsensical.
  811. X!  *    else time-value.
  812. X   * Notes:
  813. X   *    This code is quasi-public; it may be used freely in like software.
  814. X   *    It is not to be sold, nor used in licensed software without
  815. X***************
  816. X*** 22,55 ****
  817. X   *     Copyright 1981 by Ken Harrenstien, SRI International.
  818. X   *    (ARPANET: KLH @ SRI)
  819. X   */
  820. X  
  821. X  #include "cvs.h"
  822. X! #include "rcstime.h"
  823. X  
  824. X! int daytb[] = {   /* # days in year thus far, indexed by month (0-12!!) */
  825. X      0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
  826. X  };
  827. X  
  828. X! struct tm *localtime();
  829. X! long    time();
  830. X! 
  831. X! long maketime(atm)
  832. X! struct tm *atm;
  833. X! {    register struct tm *tp;
  834. X!     register int i;
  835. X!     int year, yday, mon, day, hour, min, sec, zone, dst, leap;
  836. X!     long tres, curtim;
  837. X! 
  838. X!     (void) time(&curtim);
  839. X!     tp = localtime(&curtim);        /* Get breakdowns of current time */
  840. X!     year = tp->tm_year;        /* Use to set up defaults */
  841. X!     mon = tp->tm_mon;
  842. X!     day = tp->tm_mday;
  843. X  
  844. X  
  845. X  #ifdef DEBUG
  846. X! printf("first YMD: %d %d %d, T=%ld\n",year,mon,day,tres);
  847. X! #endif DEBUG
  848. X      tp = atm;
  849. X  
  850. X      /* First must find date, using specified year, month, day.
  851. X--- 20,174 ----
  852. X   *     Copyright 1981 by Ken Harrenstien, SRI International.
  853. X   *    (ARPANET: KLH @ SRI)
  854. X   */
  855. X+ /* $Log:    maketime.c,v $
  856. X+  * Revision 1.2.1.1  91/01/18  12:15:21  berliner
  857. X+  * For CVS 1.2, contributed by Paul Eggert
  858. X+  * 
  859. X+  * Revision 1.3  1991/01/18  00:14:48  eggert
  860. X+  * Make minimal changes to interface to CVS 1.0.
  861. X+  *
  862. X+  * Revision 5.2  1990/11/01  05:03:30  eggert
  863. X+  * Remove lint.
  864. X+  *
  865. X+  * Revision 5.1  1990/10/04  06:30:13  eggert
  866. X+  * Calculate the GMT offset of 'xxx LT' as of xxx, not as of now.
  867. X+  * Don't assume time_t is 32 bits.  Fix bugs near epoch and near end of time.
  868. X+  *
  869. X+  * Revision 5.0  1990/08/22  08:12:38  eggert
  870. X+  * Switch to GMT and fix the bugs exposed thereby.
  871. X+  * Permit dates past 1999/12/31.  Ansify and Posixate.
  872. X+  *
  873. X+  * Revision 1.8  88/11/08  13:54:53  narten
  874. X+  * allow negative timezones (-24h <= x <= 24h)
  875. X+  * 
  876. X+  * Revision 1.7  88/08/28  14:47:52  eggert
  877. X+  * Allow cc -R.  Remove unportable "#endif XXX"s.
  878. X+  * 
  879. X+  * Revision 1.6  87/12/18  17:05:58  narten
  880. X+  * include rcsparam.h
  881. X+  * 
  882. X+  * Revision 1.5  87/12/18  11:35:51  narten
  883. X+  * maketime.c: fixed USG code - you have tgo call "tzset" in order to have
  884. X+  * "timezone" set. ("localtime" calls it, but it's probably better not to 
  885. X+  * count on "localtime" having been called.)
  886. X+  * 
  887. X+  * Revision 1.4  87/10/18  10:26:57  narten
  888. X+  * Updating version numbers. Changes relative to 1.0 are actually 
  889. X+  * relative to 1.2
  890. X+  * 
  891. X+  * Revision 1.3  87/09/24  13:58:45  narten
  892. X+  * Sources now pass through lint (if you ignore printf/sprintf/fprintf 
  893. X+  * warnings)
  894. X+  * 
  895. X+  * Revision 1.2  87/03/27  14:21:48  jenkins
  896. X+  * Port to suns
  897. X+  * 
  898. X+  * Revision 1.2  83/12/05  10:12:56  wft
  899. X+  * added cond. compilation for USG Unix; long timezone;
  900. X+  * 
  901. X+  * Revision 1.1  82/05/06  11:38:00  wft
  902. X+  * Initial revision
  903. X+  * 
  904. X+  */
  905. X+ 
  906. X  
  907. X+ /* minimal changes needed to get this file to work for CVS rather than RCS */
  908. X+ /* #include "rcsbase.h" */
  909. X+ #include <sys/types.h>
  910. X+ #include <time.h>
  911. X  #include "cvs.h"
  912. X! #define datesize 32
  913. X! #define faterror(x,y) error(0,x,y)
  914. X! #define libId(x,y) static char x[] = y;
  915. X! #define P(x) ()
  916. X! #define RCSversion 5
  917. X! #define VERSION(x) x
  918. X! #define VOID (void)
  919. X! #if !__STDC__
  920. X! #    define const
  921. X! #endif
  922. X! void str2date();
  923. X! Make_Date(a,b) const char *a; char *b; { str2date(a,b); }
  924. X! 
  925. X! libId(maketId, "$Id: maketime.c,v 1.2.1.1 91/01/18 12:15:21 berliner Exp $")
  926. X! 
  927. X! static const struct tm *time2tm P((time_t));
  928. X  
  929. X! #define given(v) (0 <= (v)) /* Negative values are unspecified. */
  930. X! 
  931. X! static const int daytb[] = {
  932. X!     /* # days in year thus far, indexed by month (0-12!!) */
  933. X      0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
  934. X  };
  935. X  
  936. X!     static time_t
  937. X! maketime(atm,zone)
  938. X!     const struct tm *atm;
  939. X!     int zone;
  940. X! {
  941. X!     register const struct tm *tp;
  942. X!     register int i;
  943. X!     int year, yday, mon, day, hour, min, sec, leap, localzone;
  944. X!     int attempts;
  945. X!     time_t t, tres;
  946. X! 
  947. X!     attempts = 2;
  948. X!     localzone = zone==48*60;
  949. X!     tres = -1;
  950. X!     year = mon = day = 0;  /* Keep lint happy.  */
  951. X! 
  952. X!     do {
  953. X! 
  954. X!     if (localzone || !given(atm->tm_year)) {
  955. X!         if (tres == -1)
  956. X!             if ((tres = time((time_t*)0))  ==  -1)
  957. X!                 return -1;
  958. X!         tp = time2tm(tres);
  959. X!         /* Get breakdowns of default time, adjusting to zone. */
  960. X!         year = tp->tm_year;        /* Use to set up defaults */
  961. X!         yday = tp->tm_yday;
  962. X!         mon = tp->tm_mon;
  963. X!         day = tp->tm_mday;
  964. X!         hour = tp->tm_hour;
  965. X!         min = tp->tm_min;
  966. X!         if (localzone) {
  967. X!             tp = localtime(&tres);
  968. X!             zone =
  969. X!             min - tp->tm_min + 60*(
  970. X!                 hour - tp->tm_hour + 24*(
  971. X!                     /* If years differ, it's by one day. */
  972. X!                         year - tp->tm_year
  973. X!                     ?    year - tp->tm_year
  974. X!                     :    yday - tp->tm_yday));
  975. X!         }
  976. X!         /* Adjust the default day, month and year according to zone.  */
  977. X!         if ((min -= zone) < 0) {
  978. X!             if (hour-(59-min)/60 < 0  &&  --day <= 0) {
  979. X!             if (--mon < 0) {
  980. X!                 --year;
  981. X!                 mon = 11;
  982. X!             }
  983. X!             day  =  daytb[mon+1] - daytb[mon] + (mon==1&&!(year&3));
  984. X!             }
  985. X!         } else
  986. X!             if (
  987. X!               24 <= hour+min/60  &&
  988. X!               daytb[mon+1] - daytb[mon] + (mon==1&&!(year&3))  <  ++day
  989. X!             ) {
  990. X!                 if (11 < ++mon) {
  991. X!                     ++year;
  992. X!                     mon = 0;
  993. X!                 }
  994. X!                 day = 1;
  995. X!             }
  996. X!     }
  997. X!     if (zone < -24*60  ||  24*60 < zone)
  998. X!         return -1;
  999. X  
  1000. X  
  1001. X  #ifdef DEBUG
  1002. X! printf("first YMD: %d %d %d\n",year,mon,day);
  1003. X! #endif
  1004. X      tp = atm;
  1005. X  
  1006. X      /* First must find date, using specified year, month, day.
  1007. X***************
  1008. X*** 56,228 ****
  1009. X       * If one of these is unspecified, it defaults either to the
  1010. X       * current date (if no more global spec was given) or to the
  1011. X       * zero-value for that spec (i.e. a more global spec was seen).
  1012. X!      * Start with year... note 32 bits can only handle 135 years.
  1013. X       */
  1014. X!     if(tp->tm_year != TMNULL)
  1015. X!       {    if((year = tp->tm_year) >= 1900)    /* Allow full yr # */
  1016. X!               year -= 1900;            /* by making kosher */
  1017. X          mon = 0;        /* Since year was given, default */
  1018. X          day = 1;        /* for remaining specs is zero */
  1019. X        }
  1020. X!     if(year < 70 || 70+134 < year )    /* Check range */
  1021. X!         return(0);        /* ERR: year out of range */
  1022. X!     leap = year&03 ? 0 : 1;        /* See if leap year */
  1023. X      year -= 70;            /* UNIX time starts at 1970 */
  1024. X  
  1025. X      /*
  1026. X       * Find day of year.
  1027. X-      * YDAY is used only if it exists and either the month or day-of-month
  1028. X-      * is missing.
  1029. X       */
  1030. X!     if (tp->tm_yday != TMNULL
  1031. X!      && (tp->tm_mon == TMNULL || tp->tm_mday == TMNULL))
  1032. X!         yday = tp->tm_yday;
  1033. X!     else
  1034. X!       {    if(tp->tm_mon  != TMNULL)
  1035. X            {    mon = tp->tm_mon;    /* Month was specified */
  1036. X              day = 1;        /* so set remaining default */
  1037. X            }
  1038. X!         if(mon < 0 || 11 < mon) return(0);    /* ERR: bad month */
  1039. X!         if(tp->tm_mday != TMNULL) day = tp->tm_mday;
  1040. X          if(day < 1
  1041. X           || (((daytb[mon+1]-daytb[mon]) < day)
  1042. X              && (day!=29 || mon!=1 || !leap) ))
  1043. X!                 return(0);        /* ERR: bad day */
  1044. X          yday = daytb[mon]    /* Add # of days in months so far */
  1045. X            + ((leap        /* Leap year, and past Feb?  If */
  1046. X                && mon>1)? 1:0)    /* so, add leap day for this year */
  1047. X            + day-1;        /* And finally add # days this mon */
  1048. X  
  1049. X!                 if (tp->tm_yday != TMNULL       /* Confirm that YDAY correct */
  1050. X!                  && tp->tm_yday != yday) return(0);     /* ERR: conflict */
  1051. X!       }
  1052. X!     if(yday < 0 || (leap?366:365) <= yday)
  1053. X!         return(0);        /* ERR: bad YDAY or maketime bug */
  1054. X! 
  1055. X!     tres = year*365            /* Get # days of years so far */
  1056. X          + ((year+1)>>2)        /* plus # of leap days since 1970 */
  1057. X          + yday;            /* and finally add # days this year */
  1058. X  
  1059. X-         if((i = tp->tm_wday) != TMNULL) /* Check WDAY if present */
  1060. X-                 if(i < 0 || 6 < i       /* Ensure within range */
  1061. X-                   || i != (tres+4)%7)   /* Matches? Jan 1,1970 was Thu = 4 */
  1062. X-                         return(0);      /* ERR: bad WDAY */
  1063. X- 
  1064. X  #ifdef DEBUG
  1065. X  printf("YMD: %d %d %d, T=%ld\n",year,mon,day,tres);
  1066. X! #endif DEBUG
  1067. X      /*
  1068. X       * Now determine time.  If not given, default to zeros
  1069. X       * (since time is always the least global spec)
  1070. X       */
  1071. X      tres *= 86400L;            /* Get # seconds (24*60*60) */
  1072. X      hour = min = sec = 0;
  1073. X!     if(tp->tm_hour != TMNULL) hour = tp->tm_hour;
  1074. X!     if(tp->tm_min  != TMNULL) min  = tp->tm_min;
  1075. X!     if(tp->tm_sec  != TMNULL) sec  = tp->tm_sec;
  1076. X!     if( min < 0 || 60 <= min
  1077. X!      || sec < 0 || 60 <= sec) return(0);    /* ERR: MS out of range */
  1078. X!     if(hour < 0 || 24 <= hour)
  1079. X          if(hour != 24 || (min+sec) !=0)    /* Allow 24:00 */
  1080. X!             return(0);        /* ERR: H out of range */
  1081. X! 
  1082. X!     /* confirm AM/PM if there */
  1083. X!     switch(tp->tm_ampm)
  1084. X!       {    case 0: case TMNULL:    /* Ignore these values */
  1085. X!             break;
  1086. X!         case 1:            /* AM */
  1087. X!         case 2:            /* PM */
  1088. X!             if(hour > 12) return(0);  /* ERR: hrs 13-23 bad */
  1089. X!             if(hour ==12) hour = 0;    /* Modulo 12 */
  1090. X!             if(tp->tm_ampm == 2)    /* If PM, then */
  1091. X!                 hour += 12;    /*   get 24-hour time */
  1092. X!             break;
  1093. X!         default: return(0);    /* ERR: illegal TM_AMPM value */
  1094. X!       }
  1095. X  
  1096. X!     tres += sec + 60L*(min + 60L*hour);    /* Add in # secs of time */
  1097. X  
  1098. X  #ifdef DEBUG
  1099. X  printf("HMS: %d %d %d T=%ld\n",hour,min,sec,tres);
  1100. X! #endif DEBUG
  1101. X!     /*
  1102. X!      * We now have the GMT date/time and must make final
  1103. X!      * adjustment for the specified time zone.  If none is specified,
  1104. X!      * the local time-zone is assumed.
  1105. X!      */
  1106. X!     if((zone = tp->tm_zon) == TMNULL    /* If unspecified */
  1107. X!      || (zone == 1))            /* or local-zone requested */
  1108. X!         zone = localzone();        /* then set to local zone */
  1109. X!     if(zone < 0 || 24*60 <= zone)
  1110. X!         return(0);            /* ERR: zone out of range */
  1111. X! 
  1112. X!     /* See if must apply Daylight Saving Time shift.
  1113. X!      * Note that if DST is specified, validity is not checked.
  1114. X!      */
  1115. X!     if((dst = tp->tm_isdst) == TMNULL)    /* Must we figure it out? */
  1116. X!       {    curtim = tres +localzone()*60L;    /* Yuck.  Get equiv local */
  1117. X!         dst = localtime(&curtim)->tm_isdst;     /* time, and ask. */
  1118. X!       }
  1119. X!     tres += zone*60L -(dst?3600:0);    /* Add in # seconds of zone adj */
  1120. X  
  1121. X!     return(tres);
  1122. X! }
  1123. X  
  1124. X  
  1125. X! /* LOCALZONE        return local timezone in # mins west of GMT
  1126. X!  *
  1127. X!  */
  1128. X  
  1129. X! #ifdef V6
  1130. X! extern long timezone;
  1131. X! #else
  1132. X! #ifdef USG
  1133. X! extern long timezone;
  1134. X! #else /* V7 */
  1135. X! #include <sys/types.h>
  1136. X! #include <sys/timeb.h>
  1137. X! #endif USG
  1138. X! #endif V6
  1139. X  
  1140. X! int _lclzon = -1;
  1141. X! localzone()
  1142. X  {
  1143. X! #ifdef V6
  1144. X!     return(_lclzon >= 0 ? _lclzon : (_lclzon = timezone/60L));
  1145. X! #else
  1146. X! #ifdef USG
  1147. X!     tzset();
  1148. X!     return(_lclzon >= 0 ? _lclzon : (_lclzon = timezone/60L));
  1149. X! #else /* V7 */
  1150. X!     struct timeb tb;
  1151. X! 
  1152. X!     if(_lclzon < 0)
  1153. X!       {    ftime(&tb);
  1154. X!         _lclzon = tb.timezone;
  1155. X!       }
  1156. X!     return(_lclzon);
  1157. X  
  1158. X! #endif USG
  1159. X! #endif V6
  1160. X  }
  1161. X  
  1162. X! Make_Date(rawdate, date)
  1163. X!     char *rawdate;
  1164. X!     char *date;
  1165. X  {
  1166. X!     extern int force_tag_match;
  1167. X!     struct tm parseddate, *ftm;
  1168. X!     long unixtime;
  1169. X! 
  1170. X!     /*
  1171. X!      * Dates must "match", else the file is ignored
  1172. X!      */
  1173. X!     force_tag_match = 1;
  1174. X!     if (partime(rawdate, &parseddate) == 0)
  1175. X!     error(0, "Can't parse date/time: %s", rawdate);
  1176. X!     if ((unixtime = maketime(&parseddate)) == 0L)
  1177. X!     error(0, "Inconsistent date/time: %s", rawdate);
  1178. X!     ftm = localtime(&unixtime);
  1179. X!     (void) sprintf(date, DATEFORM, ftm->tm_year, ftm->tm_mon+1,
  1180. X!          ftm->tm_mday, ftm->tm_hour, ftm->tm_min, ftm->tm_sec);
  1181. X  }
  1182. X--- 175,337 ----
  1183. X       * If one of these is unspecified, it defaults either to the
  1184. X       * current date (if no more global spec was given) or to the
  1185. X       * zero-value for that spec (i.e. a more global spec was seen).
  1186. X!      * Reject times that do not fit in time_t,
  1187. X!      * without assuming that time_t is 32 bits or is signed.
  1188. X       */
  1189. X!     if (given(tp->tm_year))
  1190. X!       {
  1191. X!         year = tp->tm_year;
  1192. X          mon = 0;        /* Since year was given, default */
  1193. X          day = 1;        /* for remaining specs is zero */
  1194. X        }
  1195. X!     if (year < 69)            /* 1969/12/31 OK in some timezones.  */
  1196. X!         return -1;        /* ERR: year out of range */
  1197. X!     leap   =   !(year&3)  &&  (year%100 || !((year+300)%400));
  1198. X      year -= 70;            /* UNIX time starts at 1970 */
  1199. X  
  1200. X      /*
  1201. X       * Find day of year.
  1202. X       */
  1203. X!     {
  1204. X!         if (given(tp->tm_mon))
  1205. X            {    mon = tp->tm_mon;    /* Month was specified */
  1206. X              day = 1;        /* so set remaining default */
  1207. X            }
  1208. X!         if (11 < (unsigned)mon)
  1209. X!             return -1;        /* ERR: bad month */
  1210. X!         if (given(tp->tm_mday)) day = tp->tm_mday;
  1211. X          if(day < 1
  1212. X           || (((daytb[mon+1]-daytb[mon]) < day)
  1213. X              && (day!=29 || mon!=1 || !leap) ))
  1214. X!                 return -1;    /* ERR: bad day */
  1215. X          yday = daytb[mon]    /* Add # of days in months so far */
  1216. X            + ((leap        /* Leap year, and past Feb?  If */
  1217. X                && mon>1)? 1:0)    /* so, add leap day for this year */
  1218. X            + day-1;        /* And finally add # days this mon */
  1219. X  
  1220. X!     }
  1221. X!     if (leap+365 <= (unsigned)yday)
  1222. X!         return -1;        /* ERR: bad YDAY */
  1223. X! 
  1224. X!     if (year < 0) {
  1225. X!         if (yday != 364)
  1226. X!         return -1;        /* ERR: too early */
  1227. X!         t = -1;
  1228. X!     } else {
  1229. X!         tres = year*365;        /* Get # days of years so far */
  1230. X!         if (tres/365 != year)
  1231. X!             return -1;        /* ERR: overflow */
  1232. X!         t = tres
  1233. X          + ((year+1)>>2)        /* plus # of leap days since 1970 */
  1234. X          + yday;            /* and finally add # days this year */
  1235. X+         if (t+4 < tres)
  1236. X+             return -1;        /* ERR: overflow */
  1237. X+     }
  1238. X+     tres = t;
  1239. X+ 
  1240. X+     if (given(i = tp->tm_wday)) /* Check WDAY if present */
  1241. X+         if (i != (tres+4)%7)    /* 1970/01/01 was Thu = 4 */
  1242. X+             return -1;    /* ERR: bad WDAY */
  1243. X  
  1244. X  #ifdef DEBUG
  1245. X  printf("YMD: %d %d %d, T=%ld\n",year,mon,day,tres);
  1246. X! #endif
  1247. X      /*
  1248. X       * Now determine time.  If not given, default to zeros
  1249. X       * (since time is always the least global spec)
  1250. X       */
  1251. X      tres *= 86400L;            /* Get # seconds (24*60*60) */
  1252. X+     if (tres/86400L != t)
  1253. X+         return -1;        /* ERR: overflow */
  1254. X      hour = min = sec = 0;
  1255. X!     if (given(tp->tm_hour)) hour = tp->tm_hour;
  1256. X!     if (given(tp->tm_min )) min  = tp->tm_min;
  1257. X!     if (given(tp->tm_sec )) sec  = tp->tm_sec;
  1258. X!     if (60 <= (unsigned)min  ||  60 < (unsigned)sec)
  1259. X!         return -1;        /* ERR: MS out of range */
  1260. X!     if (24 <= (unsigned)hour)
  1261. X          if(hour != 24 || (min+sec) !=0)    /* Allow 24:00 */
  1262. X!             return -1;    /* ERR: H out of range */
  1263. X  
  1264. X!     t = tres;
  1265. X!     tres += sec + 60L*(zone + min + 60*hour);
  1266. X  
  1267. X  #ifdef DEBUG
  1268. X  printf("HMS: %d %d %d T=%ld\n",hour,min,sec,tres);
  1269. X! #endif
  1270. X  
  1271. X!     if (!localzone)            /* check for overflow */
  1272. X!         return (year<0 ? (tres<0||86400L<=tres) : tres<t)  ?  -1  :  tres;
  1273. X  
  1274. X+     /* Check results; LT may have had a different GMT offset back then.  */
  1275. X+     tp = localtime(&tres);
  1276. X+     if (given(atm->tm_sec)  &&  atm->tm_sec != tp->tm_sec)
  1277. X+         return -1; /* If seconds don't match, we're in trouble.  */
  1278. X+     if (!(
  1279. X+         given(atm->tm_min)  &&  atm->tm_min != tp->tm_min  ||
  1280. X+         given(atm->tm_hour)  &&  atm->tm_hour != tp->tm_hour  ||
  1281. X+         given(atm->tm_mday)  &&  atm->tm_mday != tp->tm_mday  ||
  1282. X+         given(atm->tm_mon)  &&  atm->tm_mon != tp->tm_mon  ||
  1283. X+         given(atm->tm_year)  &&  atm->tm_year != tp->tm_year
  1284. X+     ))
  1285. X+         return tres; /* Everything matches.  */
  1286. X  
  1287. X!     } while (--attempts);
  1288. X  
  1289. X!     return -1;
  1290. X! }
  1291. X  
  1292. X! /*
  1293. X! * Convert Unix time to struct tm format.
  1294. X! * Use Coordinated Universal Time (UTC) if available and if version 5 or newer;
  1295. X! * use local time otherwise.
  1296. X! */
  1297. X!     static const struct tm *
  1298. X! time2tm(unixtime)
  1299. X!     time_t unixtime;
  1300. X  {
  1301. X!     const struct tm *tm;
  1302. X!     return
  1303. X!             VERSION(5)<=RCSversion && (tm = gmtime(&unixtime))
  1304. X!         ?    tm
  1305. X!         :    localtime(&unixtime);
  1306. X! }
  1307. X  
  1308. X! /*
  1309. X! * Convert Unix time to RCS format.
  1310. X! * For compatibility with older versions of RCS,
  1311. X! * dates before AD 2000 are stored without the leading "19".
  1312. X! */
  1313. X!     void
  1314. X! time2date(unixtime,date)
  1315. X!     time_t unixtime;
  1316. X!     char date[datesize];
  1317. X! {
  1318. X!     register const struct tm *tm = time2tm(unixtime);
  1319. X!     VOID sprintf(date, DATEFORM,
  1320. X!         tm->tm_year  +  (tm->tm_year<100 ? 0 : 1900),
  1321. X!         tm->tm_mon+1, tm->tm_mday,
  1322. X!         tm->tm_hour, tm->tm_min, tm->tm_sec
  1323. X!     );
  1324. X  }
  1325. X  
  1326. X! 
  1327. X! 
  1328. X!     void
  1329. X! str2date(source, target)
  1330. X!     const char *source;
  1331. X!     char target[datesize];
  1332. X! /* Parse a free-format date in SOURCE, convert it
  1333. X!  * into RCS internal format, and store the result into TARGET.
  1334. X!  */
  1335. X  {
  1336. X!     int zone;
  1337. X!     time_t unixtime;
  1338. X!     struct tm parseddate;
  1339. X! 
  1340. X!     if (!partime(source, &parseddate, &zone))
  1341. X!         faterror("can't parse date/time: %s", source);
  1342. X!     if ((unixtime = maketime(&parseddate, zone))  ==  -1)
  1343. X!         faterror("bad date/time: %s", source);
  1344. X!     time2date(unixtime, target);
  1345. X  }
  1346. Xdiff -c src/modules.c:1.14 src/modules.c:1.14.1.1
  1347. X*** src/modules.c:1.14    Wed Feb  6 11:32:12 1991
  1348. X--- src/modules.c    Wed Feb  6 11:32:13 1991
  1349. X***************
  1350. X*** 1,5 ****
  1351. X  #ifndef lint
  1352. X! static char rcsid[] = "$Id: modules.c,v 1.14 89/11/19 23:20:12 berliner Exp $";
  1353. X  #endif !lint
  1354. X  
  1355. X  /*
  1356. X--- 1,5 ----
  1357. X  #ifndef lint
  1358. X! static char rcsid[] = "$Id: modules.c,v 1.14.1.1 91/01/29 07:17:32 berliner Exp $";
  1359. X  #endif !lint
  1360. X  
  1361. X  /*
  1362. X***************
  1363. X*** 268,273 ****
  1364. X--- 268,274 ----
  1365. X          err += patched((char *)0);
  1366. X      else
  1367. X          error(0, "impossible module type %d", (int)m_type);
  1368. X+     update_dir[0] = '\0';
  1369. X      return (err);
  1370. X      }
  1371. X      argc--;
  1372. Xdiff -c src/no_difference.c:1.7 src/no_difference.c:1.7.1.1
  1373. X*** src/no_difference.c:1.7    Wed Feb  6 11:32:09 1991
  1374. X--- src/no_difference.c    Wed Feb  6 11:32:09 1991
  1375. X***************
  1376. X*** 1,5 ****
  1377. X  #ifndef lint
  1378. X! static char rcsid[] = "$Id: no_difference.c,v 1.7 89/11/19 23:20:16 berliner Exp $";
  1379. X  #endif !lint
  1380. X  
  1381. X  /*
  1382. X--- 1,5 ----
  1383. X  #ifndef lint
  1384. X! static char rcsid[] = "$Id: no_difference.c,v 1.7.1.1 91/01/29 07:18:06 berliner Exp $";
  1385. X  #endif !lint
  1386. X  
  1387. X  /*
  1388. X***************
  1389. X*** 39,45 ****
  1390. X          xchmod(User, 0);
  1391. X          Version_TS(Rcs, Tag, User);
  1392. X          (void) strcpy(TS_Rcs, TS_User);
  1393. X!         Register(User, VN_Rcs, TS_User);
  1394. X          if (doGlist) {
  1395. X          (void) strcat(Olist, " ");
  1396. X          (void) strcat(Olist, User);
  1397. X--- 39,45 ----
  1398. X          xchmod(User, 0);
  1399. X          Version_TS(Rcs, Tag, User);
  1400. X          (void) strcpy(TS_Rcs, TS_User);
  1401. X!         Register(User, VN_User[0] ? VN_User : VN_Rcs, TS_User);
  1402. X          if (doGlist) {
  1403. X          (void) strcat(Olist, " ");
  1404. X          (void) strcat(Olist, User);
  1405. Xdiff -c src/partime.c:1.1 src/partime.c:1.1.1.1
  1406. X*** src/partime.c:1.1    Wed Feb  6 11:32:07 1991
  1407. X--- src/partime.c    Wed Feb  6 11:32:07 1991
  1408. X***************
  1409. X*** 1,17 ****
  1410. X- #ifndef lint
  1411. X- static char rcsid[] = "$Id: partime.c,v 1.1 89/05/09 11:51:02 berliner Exp $";
  1412. X- #endif
  1413. X- 
  1414. X  /*
  1415. X   * PARTIME        parse date/time string into a TM structure
  1416. X   *
  1417. X-  * Usage:
  1418. X-  *      #include "time.h"             -- expanded tm structure
  1419. X-  *    char *str; struct tm *tp;
  1420. X-  *    partime(str,tp);
  1421. X   * Returns:
  1422. X   *    0 if parsing failed
  1423. X!  *    else time values in specified TM structure (unspecified values
  1424. X   *        set to TMNULL)
  1425. X   * Notes:
  1426. X   *    This code is quasi-public; it may be used freely in like software.
  1427. X--- 1,9 ----
  1428. X  /*
  1429. X   * PARTIME        parse date/time string into a TM structure
  1430. X   *
  1431. X   * Returns:
  1432. X   *    0 if parsing failed
  1433. X!  *    else time values in specified TM structure and zone (unspecified values
  1434. X   *        set to TMNULL)
  1435. X   * Notes:
  1436. X   *    This code is quasi-public; it may be used freely in like software.
  1437. X***************
  1438. X*** 26,58 ****
  1439. X   *    If parsing changed so that no backup needed, could perhaps modify
  1440. X   *        to use a FILE input stream.  Need terminator, though.
  1441. X   *    Perhaps should return 0 on success, else a non-zero error val?
  1442. X-  *    Flush AMPM from TM structure and handle locally within PARTIME,
  1443. X-  *        like midnight/noon?
  1444. X   */
  1445. X  
  1446. X! #include <stdio.h>
  1447. X! #include <ctype.h>
  1448. X! #include "rcstime.h"
  1449. X  
  1450. X! #ifndef lint
  1451. X! static char timeid[] = TIMEID;
  1452. X  #endif
  1453. X  
  1454. X  struct tmwent {
  1455. X!     char *went;
  1456. X!     long wval;    /* must be big enough to hold pointer or integer */
  1457. X      char wflgs;
  1458. X      char wtype;
  1459. X  };
  1460. X      /* wflgs */
  1461. X- #define TWSPEC 01    /* Word wants special processing */
  1462. X  #define TWTIME 02    /* Word is a time value (absence implies date) */
  1463. X  #define TWDST  04    /* Word is a DST-type timezone */
  1464. X! #define TW1200 010    /* Word is NOON or MIDNIGHT (sigh) */
  1465. X  
  1466. X! int pt12hack();
  1467. X! int ptnoise();
  1468. X! struct tmwent tmwords [] = {
  1469. X      {"january",      0, 0, TM_MON},
  1470. X      {"february",     1, 0, TM_MON},
  1471. X      {"march",        2, 0, TM_MON},
  1472. X--- 18,106 ----
  1473. X   *    If parsing changed so that no backup needed, could perhaps modify
  1474. X   *        to use a FILE input stream.  Need terminator, though.
  1475. X   *    Perhaps should return 0 on success, else a non-zero error val?
  1476. X   */
  1477. X  
  1478. X! /* $Log:    partime.c,v $
  1479. X!  * Revision 1.1.1.1  91/01/18  12:18:12  berliner
  1480. X!  * For CVS 1.2, contributed by Paul Eggert
  1481. X!  * 
  1482. X!  * Revision 1.2  1991/01/18  00:14:49  eggert
  1483. X!  * Make minimal changes to interface to CVS 1.0.
  1484. X!  *
  1485. X!  * Revision 5.4  1990/10/04  06:30:15  eggert
  1486. X!  * Remove date vs time heuristics that fail between 2000 and 2400.
  1487. X!  * Check for overflow when lexing an integer.
  1488. X!  * Parse 'Jan 10 LT' as 'Jan 10, LT', not 'Jan, 10 LT'.
  1489. X!  *
  1490. X!  * Revision 5.3  1990/09/24  18:56:31  eggert
  1491. X!  * Update timezones.
  1492. X!  *
  1493. X!  * Revision 5.2  1990/09/04  08:02:16  eggert
  1494. X!  * Don't parse two-digit years, because it won't work after 1999/12/31.
  1495. X!  * Don't permit 'Aug Aug'.
  1496. X!  *
  1497. X!  * Revision 5.1  1990/08/29  07:13:49  eggert
  1498. X!  * Be able to parse our own date format.  Don't assume year<10000.
  1499. X!  *
  1500. X!  * Revision 5.0  1990/08/22  08:12:40  eggert
  1501. X!  * Switch to GMT and fix the bugs exposed thereby.  Update timezones.
  1502. X!  * Ansify and Posixate.  Fix peekahead and int-size bugs.
  1503. X!  *
  1504. X!  * Revision 1.4  89/05/01  14:48:46  narten
  1505. X!  * fixed #ifdef DEBUG construct
  1506. X!  * 
  1507. X!  * Revision 1.3  88/08/28  14:53:40  eggert
  1508. X!  * Remove unportable "#endif XXX"s.
  1509. X!  * 
  1510. X!  * Revision 1.2  87/03/27  14:21:53  jenkins
  1511. X!  * Port to suns
  1512. X!  * 
  1513. X!  * Revision 1.1  82/05/06  11:38:26  wft
  1514. END_OF_FILE
  1515.   if test 49821 -ne `wc -c <'Patch02.01'`; then
  1516.     echo shar: \"'Patch02.01'\" unpacked with wrong size!
  1517.   fi
  1518.   # end of 'Patch02.01'
  1519. fi
  1520. echo shar: End of archive 1 \(of 2\).
  1521. cp /dev/null ark1isdone
  1522. MISSING=""
  1523. for I in 1 2 ; do
  1524.     if test ! -f ark${I}isdone ; then
  1525.     MISSING="${MISSING} ${I}"
  1526.     fi
  1527. done
  1528. if test "${MISSING}" = "" ; then
  1529.     echo You have unpacked both archives.
  1530.     rm -f ark[1-9]isdone
  1531. else
  1532.     echo You still must unpack the following archives:
  1533.     echo "        " ${MISSING}
  1534. fi
  1535. exit 0
  1536. exit 0 # Just in case...
  1537.